import java.util.ArrayList;
import java.util.Scanner;

public class Test3 {
    public static void main(String[] args) {
        ArrayList<Student> List = new ArrayList<>();
        Scanner sc = new Scanner(System.in);
        for (int i = 0; i < 3; i++) {
            Student s = new Student();
            System.out.println("请输入年龄");
            int age = sc.nextInt();
            System.out.println("请输入名字");
            String name = sc.next();
            s.setAge(age);
            s.setName(name);
            List.add(s);
        }
        for (int i = 0; i < List.size(); i++) {
            Student stu = List.get(i);
            System.out.println(stu.getAge()+stu.getName());
        }

    }
}
